package com.itheima.thread05;
import java.util.concurrent.ArrayBlockingQueue;

//测试类
public class Demo {
    public static void main(String[] args) {
        ArrayBlockingQueue<String> list = new ArrayBlockingQueue<>(1);

        Cooker c= new Cooker(list);
        Foodie f = new Foodie(list);

        Thread t1 = new Thread(c);
        Thread t2 = new Thread(f);

        t1.start();
        t2.start();
    }
}
